import { _decorator } from 'cc';
import { PanelBase } from '../../Basic/UI/PanelBase';
import { LayerType } from '../../Basic/Config/BaseEnum';
import { List } from '../../Basic/Component/List';
import { PropModel } from './PropModel';
const { ccclass, property } = _decorator;

export class PropCellType {
  propId: number;
  constructor(id) {
    this.propId = id;
  }
}

@ccclass('PropPanel')
export class PropPanel extends PanelBase {
  panelLayer: LayerType.DialogLayer = LayerType.DialogLayer;

  @property(List)
  propList: List;

  protected onEnable(): void {
    const listData = PropModel.Ins().getListData();
    this.propList.setData(listData);
  }
}
